<div class="sui-form form-horizontal">
    <div class="control-group">
        <label class="control-label v-top"><b style="color: #f00;">*</b>模板名称：</label>
        <div class="controls">
            <input ng-model="period_stls.title" value="" name="sale_num" class="ng-pristine ng-untouched ng-valid">
        </div>
    </div>
    <div class="control-group">
        <label class="control-label v-top">特殊日期设置:</label>
        <div class="controls">
            <div class="sui-row-fluid" style="    width: 629px;">
                <div class="span2">
                    按周几避开:
                    <week-select ng-model="period_stls.exclude_by_week" callback="weekciclk(da)"></week-select>
                </div>
                <div class="span6">
                    <date-select ng-model="period_stls.exclude_by_date"></date-select>
                </div>
            </div>
        </div>
    </div>
</div>
<div>
    <table class="sui-table table-bordered">
        <thead>
            <tr>
                <th ng-repeat="(key,list) in period_stls.periods" ng-show="!list.show" ng-if="period_stls.type_id == 1" >{{list.name}}
                </th>
                <th ng-repeat="(key,list) in period_stls.periods"  ng-if="period_stls.type_id == 2" >{{list.name}}
                </th>
            </tr>
        </thead>
        <tbody>
            <tr>
                <td ng-repeat="(ke,sub) in period_stls.periods" ng-show="!sub.show">
                    <a href="javascript:;" class="sui-btn btn-success btn-small" ng-click="addtimeslots(sub.timeslots);" style="margin-bottom: 10px;">+增加时段</a>
                    <div class="control-group" ng-repeat="(k,value) in sub.timeslots">
                        <label class="control-label v-top">
                        </label>
                        <div class="controls">
                            时间:
                            <input ng-model="value.start" name="name" value="" class="input-mini" style="width: 35px">~
                            <input ng-model="value.end" name="name" value="" style="width: 35px" ng-blur="Testing(value.end,value.start)">
                            <!-- 预约人数: -->
                            数量:
                            <input ng-model="value.max_count" type="number" name="max_count" value="" class="input-mini" style="width: 30px">
                            <a data-no-drag="" ng-click="sub.timeslots.splice($index,1)"><i class="fa fa-times fa-1"></i></a>
                        </div>
                    </div>
                </td>
            </tr>
        </tbody>
    </table>
    <span class="sui-form sui-form pull-right"> 
          <button class="sui-btn btn-primary" type="submit" ng-click="saveData($evtnt)">{{'保存'|translate}}</button>
    </span>
</div>